/**
 * 
 */
package javapop.framework.generic;

import javapop.framework.generic.tool.GrammarVisitor;

/**
 * @author hakim
 *
 */
public class GIgnore implements GParser {

	private GParser parser;
	
	
	/**
	 * @param p 
	 * 
	 */
	public GIgnore(GParser p) {
		parser = p;
	}
	
	public GParser getParser() {
		return parser;
	}

	@Override
	public <T,R,E extends Exception> T visit(GrammarVisitor<T,R, E> g) throws E {
		return g.visit(this);
	}

	@Override
	public String toString() {
		return "@ignore("+parser+");";
	}

}
